package com.ruoyi.income.mapper;

import java.util.List;
import com.ruoyi.income.domain.HouseContarctIncome;
import com.ruoyi.income.domain.SumContarctIncome;
import org.apache.ibatis.annotations.Param;
import org.springframework.security.core.parameters.P;

/**
 * 计划详情Mapper接口
 * 
 * @author hct
 * @date 2022-02-16
 */
public interface HouseContarctIncomeMapper 
{
    /**
     * 查询计划详情
     * 
     * @param id 计划详情主键
     * @return 计划详情
     */
    public HouseContarctIncome selectHouseContarctIncomeById(Long id);

    /**
     * 查询计划详情列表
     * 
     * @param houseContarctIncome 计划详情
     * @return 计划详情集合
     */
    public List<HouseContarctIncome> selectHouseContarctIncomeList(HouseContarctIncome houseContarctIncome);

    /**
     * 新增计划详情
     * 
     * @param houseContarctIncome 计划详情
     * @return 结果
     */
    public int insertHouseContarctIncome(HouseContarctIncome houseContarctIncome);

    /**
     * 修改计划详情
     * 
     * @param houseContarctIncome 计划详情
     * @return 结果
     */
    public int updateHouseContarctIncome(HouseContarctIncome houseContarctIncome);

    /**
     * 删除计划详情
     * 
     * @param id 计划详情主键
     * @return 结果
     */
    public int deleteHouseContarctIncomeById(Long id);

    /**
     * 批量删除计划详情
     * 
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteHouseContarctIncomeByIds(Long[] ids);


    /**
     * 根据id 查询所有未完成结算的明细
     * @param ids
     * @return
     */
    public List<HouseContarctIncome> selectHouseContarctIncomeByIds(@Param("ids") Long[] ids);


    public SumContarctIncome sumIncome(@Param("income") HouseContarctIncome income);


    public int insertIncomeList(@Param("incomes") List<HouseContarctIncome> incomes);

    public HouseContarctIncome getLastId();

    public int updateIncomeByIds(@Param("imcome")HouseContarctIncome imcome, @Param("ids") List<Long> ids);
}
